package com.baoyouqun.domain.CreateCmd;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.time.LocalDateTime;

@Data
public class UserPointsCreateCmd implements Serializable {

    private static final long serialVersionUID = 1L;
    // 自定义的查询内容
    @ApiModelProperty(value = "用户ID（关联用户表）")
    private String userId;

    @ApiModelProperty(value = "当前可用积分")
    private Integer currentPoints = 0;

    @ApiModelProperty(value = "累计获取积分（历史总积分）")
    private Integer totalPoints = 0;

    @ApiModelProperty(value = "冻结积分（如兑换中未完成）")
    private Integer frozenPoints = 0;

    @ApiModelProperty(value = "最后更新时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "创建时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;


}